package com.ferris.redbook.entity;

import com.baomidou.mybatisplus.annotation.*;
import lombok.Builder;
import lombok.Data;

import java.time.LocalDateTime;
import java.util.Date;

@Data
@TableName("users")
@Builder
public class User {
    @TableId(type = IdType.AUTO)
    private Long id;

    private String email;
    private String password;
    private String nickname;
    private String avatar;
    private String bio;
    private String gender;
    private String location;
    private Date birthday;

    @TableField(fill = FieldFill.INSERT)
    private LocalDateTime createdAt;

    @TableField(fill = FieldFill.INSERT_UPDATE)
    private LocalDateTime updatedAt;

    private LocalDateTime lastLogin;
    private Integer status;
}